#include<mutex>
#include<queue>
#include<condition_variable>

class Taskqueue{
public:
    Taskqueue(size_t capa);
    void push(int num);
    int pop();
    //实现也就是逻辑
    //构造
    //插入
    //删除
    //判空
    //判满
private:
    bool full();
    bool empty();
private:
    //成员
    //_capacity
    //_queue
    //condtion_full
    //condition_empty
    //mutex
    size_t _capacity;
    std::queue<int> _queue;
    std::mutex _mtl;
    std::condition_variable _not_full;
    std::condition_variable _not_empty;
};
